/**
 * 路由的配置
 */

import userConf from './routers/userConf';
import vue2 from './routers/vue2';
import vue3 from './routers/vue3';
import purehtml from './routers/purehtml';

export default [
  
  // webpack5 远程组件
  { path: '/remoteComp', component: '@/pages/RemoteComp' },

  // qiankun 远程组件
  { path: '/qiankunComp', component: '@/pages/QiankunComp' },

  {
    path: '/',
    component: '@/layouts/BasicLayout',
    routes: [
      // 首页
      {
        path: '/home',
        exact: false,
        component: '@/pages/Home',
      },

      // 用户服务
      {
        path: '/user',
        exact: false,
        component: '@/pages/microApps/User',
      },

      // 菜单
      {
        path: '/',
        component: '@/layouts/MenuLayout',
        wrappers: ['@/components/wrappers/Authorized'],
        authority: ['login'],
        type: 'login',
        routes: [
          { path: '/', redirect: '/home' },
          ...userConf,
          ...vue2,
          ...vue3,
          ...purehtml,
          { component: '404' },
        ],
      },
    ],
  },
];
